package com.tvunetworks.center.user.model.json;
/**
 * @program: tvucc-aggregator
 * @description: InstancePeerId
 * @author lebronchen
 * @create: 2020-04-23 16:26
 **/
public class DeviceVo implements Comparable<DeviceVo>{
    private String peerId;
    private String name;
    private String status;
    private String rVersion;
    private String rIp;
    private String livePeerId;
    private String livePeerName;
    private int postion;
    private String liveUrl;
    
    public DeviceVo() {
        super();
    }

    public DeviceVo(String peerId, String name, String status, String rVersion, String rIp, String livePeerId, String livePeerName, int postion) {
        super();
        this.peerId = peerId;
        this.name = name;
        this.status = status;
        this.rVersion = rVersion;
        this.rIp = rIp;
        this.livePeerId = livePeerId;
        this.livePeerName = livePeerName;
        this.postion = postion;
    }

    public String getPeerId() {
        return peerId;
    }
    
    public void setPeerId(String peerId) {
        this.peerId = peerId;
    }
    
    public String getName() {
        return name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    
    public String getStatus() {
        return status;
    }
    
    public void setStatus(String status) {
        this.status = status;
    }

    /**
     *
     * @return String
     */
    public String getrVersion() {
        return rVersion;
    }

    /**
     *
     * @param rVersion rVersion
     */
    public void setrVersion(String rVersion) {
        this.rVersion = rVersion;
    }

    /**
     *
     * @return String
     */
    public String getrIp() {
        return rIp;
    }

    /**
     *
     * @param rIp setrIp
     */
    public void setrIp(String rIp) {
        this.rIp = rIp;
    }
    
    public String getLivePeerId() {
        return livePeerId;
    }
    
    public void setLivePeerId(String livePeerId) {
        this.livePeerId = livePeerId;
    }
    
    public String getLivePeerName() {
        return livePeerName;
    }
    
    public void setLivePeerName(String livePeerName) {
        this.livePeerName = livePeerName;
    }
    
    public int getPostion() {
        return postion;
    }
    
    public void setPostion(int postion) {
        this.postion = postion;
    }
    
    public String getLiveUrl() {
		return liveUrl;
	}

	public void setLiveUrl(String liveUrl) {
		this.liveUrl = liveUrl;
	}

	@Override
    public String toString() {
        return "DeviceVo [peerId=" + peerId + ", name=" + name + ", status=" + status + ", rVersion=" + rVersion + ", rIp=" + rIp + ", livePeerId=" + livePeerId + ", livePeerName=" + livePeerName + ", postion=" + postion + "]";
    }

    @Override
    public int compareTo(DeviceVo o) {
        return 0;
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((livePeerId == null) ? 0 : livePeerId.hashCode());
        result = prime * result + ((livePeerName == null) ? 0 : livePeerName.hashCode());
        result = prime * result + ((name == null) ? 0 : name.hashCode());
        result = prime * result + ((peerId == null) ? 0 : peerId.hashCode());
        result = prime * result + postion;
        result = prime * result + ((rIp == null) ? 0 : rIp.hashCode());
        result = prime * result + ((rVersion == null) ? 0 : rVersion.hashCode());
        result = prime * result + ((status == null) ? 0 : status.hashCode());
        return result;
    }

    @Override
    public boolean equals(Object obj) {
        if (this == obj){

            return true;
        }
        if (obj == null){

            return false;
        }
        if (getClass() != obj.getClass()){

            return false;
        }
        DeviceVo other = (DeviceVo) obj;
        if (livePeerId == null) {
            if (other.livePeerId != null){

                return false;
            }
        } else if (!livePeerId.equals(other.livePeerId)){

            return false;
        }
        if (livePeerName == null) {
            if (other.livePeerName != null){

                return false;
            }
        } else if (!livePeerName.equals(other.livePeerName)){

            return false;
        }
        if (name == null) {
            if (other.name != null){

                return false;
            }
        } else if (!name.equals(other.name)){

            return false;
        }
        if (peerId == null) {
            if (other.peerId != null){

                return false;
            }
        } else if (!peerId.equals(other.peerId)){

            return false;
        }
        if (postion != other.postion){

            return false;
        }
        if (rIp == null) {
            if (other.rIp != null){

                return false;
            }
        } else if (!rIp.equals(other.rIp)){

            return false;
        }
        if (rVersion == null) {
            if (other.rVersion != null){

                return false;
            }
        } else if (!rVersion.equals(other.rVersion)){

            return false;
        }
        if (status == null) {
            if (other.status != null){

                return false;
            }
        } else if (!status.equals(other.status)){

            return false;
        }
        return true;
    }
}
